Skip to content

Update db.migrations.operations #2349

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 4, 2025

Conversation

Viicos
Copy link
Contributor

@Viicos Viicos commented Aug 22, 2024

I have made things!

Related issues

Comment on lines +11 to +17
class OperationCategory(str, Enum):
ADDITION = "+"
REMOVAL = "-"
ALTERATION = "~"
PYTHON = "p"
SQL = "s"
MIXED = "?"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Having the actual values seems to be recommended.

Comment on lines +20 to +25
reversible: ClassVar[bool]
reduces_to_sql: ClassVar[bool]
atomic: ClassVar[bool]
elidable: ClassVar[bool]
serialization_expand_args: ClassVar[list[str]]
category: ClassVar[OperationCategory | None]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe they are all class vars?

@Viicos
Copy link
Contributor Author

Viicos commented Aug 22, 2024

The stubtest error is annoying.. Looks like mixing str and Enum doesn't play well

@Viicos Viicos force-pushed the operation-category branch from efc10cb to 79183d1 Compare August 24, 2024 08:37
Copy link
Member

@sobolevn sobolevn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, just one question

@adamchainz adamchainz force-pushed the operation-category branch from 6352413 to e6cf216 Compare March 4, 2025 11:55
@sobolevn sobolevn merged commit 735f55b into typeddjango:master Mar 4, 2025
40 checks passed
@adamchainz
Copy link
Contributor

Thanks @Viicos and @sobolevn

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants